package com.tbit.uqbike.client.pojo.aliyun;

import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;

/**
 * 车牌拍照还车sls日志推送类
 *
 * @author <a href="mailto:chen.xiaoliang@tbit.com.cn">chen</a>
 * @version 1.0
 * @see <a href="#">车牌拍照还车sls日志推送类</a>
 * @since 2024/12/11
 */
@Data
@ToString
@NoArgsConstructor
public class LicensePhotoData {
    /**
     * 订单编号
     */
    private String orderNO;
    /**
     * 设备编号
     */
    private String machineNO;
    /**
     * 区域id
     */
    private Integer accountId;
    /**
     * 设备经度
     */
    private Double machineLon;
    /**
     * 设备纬度
     */
    private Double machineLat;
    /**
     * 手机经度
     */
    private Double phoneLon;
    /**
     * 手机纬度
     */
    private Double phoneLat;
    /**
     * 照片地址
     */
    private String photoUrl;
    /**
     * 添加时间
     */
    private String addTime;
    /**
     * 车辆位置是否超区
     */
    private Boolean machineOutArea;
    /**
     * 手机位置是否超区
     */
    private Boolean phoneOutArea;
    /**
     * 识别结果
     */
    private Boolean result;

    public LicensePhotoData(String orderNO, String machineNO, Integer accountId, String photoUrl, String addTime, Boolean result) {
        this.orderNO = orderNO;
        this.machineNO = machineNO;
        this.accountId = accountId;
        this.photoUrl = photoUrl;
        this.addTime = addTime;
        this.result = result;
    }

    public static void main(String[] args) {
        LicensePhotoData licensePhotoData = new LicensePhotoData("123", "123", 1, "123", "2024-12-11 12:00:00", true);
        licensePhotoData.setMachineLon(1.0);
        licensePhotoData.setMachineLat(2.0);
        licensePhotoData.setPhoneLon(3.0);
        licensePhotoData.setPhoneLat(4.0);
        licensePhotoData.setMachineOutArea(true);
        licensePhotoData.setPhoneOutArea(false);
        JSONObject jsonObject=new JSONObject();
        jsonObject.put("feedback","");
        jsonObject.put("data",licensePhotoData);
        jsonObject.put("msgId","51006");
        System.out.println(JSON.toJSONString(jsonObject));
    }
}